package com.qianniu.napi.admin.service.impl;

import com.qianniu.napi.admin.entity.CouponTpl;
import com.qianniu.napi.admin.mapper.CouponTplMapper;
import com.qianniu.napi.admin.service.ICouponTplService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 优惠券模板 服务实现类
 * </p>
 *
 * @author chenxuebin
 * @since 2018-07-07
 */
@Service
public class CouponTplServiceImpl extends ServiceImpl<CouponTplMapper, CouponTpl> implements ICouponTplService {

    @Autowired
    private CouponTplMapper couponTplMapper;

    public List<CouponTpl> getMechantCouponstpl(long mpid){

        return couponTplMapper.getMechantCouponstpl(mpid);
    }

    public List<CouponTpl> getMechantCoupons(long mid,long uid){

        return couponTplMapper.getMechantCoupons(mid,uid);
    }

    public List<CouponTpl> getHomeCoupons(Long mid,Long uid){

        return couponTplMapper.getHomeCoupons(mid,uid);
    }
}
